package com.job.createType.abstractFactory;


/**
 * @Author 王博
 * @DateTime 2025-04-08 16:13
 */
public class DessertShop {
    public static void main(String[] args) {
        DessertShop.createDessert(new FranceFactory());
    }

    public static void createDessert(CoffeeBreadFactory factory) {
        Coffee coffee = factory.createCoffee();
        System.out.println(coffee.getCoffeeName());
        Bread bread = factory.createBread();
        System.out.println(bread.getBreadName());
    }
}
